-- GENERATED SPELL FOR [Doomforge Dragoon] --


function spell0_8899(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15496,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8899', 578, 1)
end

function spell1_8899(pUnit, Event) --@Explosive Shot,n/a--
pUnit:FullCastSpellOnTarget(15495,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8899', 1000, 1)
end

function spell2_8899(pUnit, Event) --@Shoot,n/a--
pUnit:FullCastSpellOnTarget(15620,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8899', 601, 1)
end

function Sorts_8899(pUnit, Event)
local choix_sorts_8899 = math.random(0, 2)
if choix_sorts_8899 == 0 then
pUnit:RegisterEvent('spell0_8899', 1, 1)
end
if choix_sorts_8899 == 1 then
pUnit:RegisterEvent('spell1_8899', 1, 1)
end
if choix_sorts_8899 == 2 then
pUnit:RegisterEvent('spell2_8899', 1, 1)
end
end

function mob8899_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_8899', math.random(1500, 3000), 1)
end

function mob8899_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8899_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8899_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(8899, 1, 'mob8899_Action')
RegisterUnitEvent(8899, 2, 'mob8899_Leave')
RegisterUnitEvent(8899, 3, 'mob8899_Kill')
RegisterUnitEvent(8899, 4, 'mob8899_Die')
